<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>店铺订单详情页 - ${web.name}${web.additionalTitle!}</title>
<link href="${root}/u/css/main.css" type="text/css" rel="stylesheet" />
<link href="${root}/u/css/memeber.css" type="text/css" rel="stylesheet" />
<link href="${root}/u/css/order.css" type="text/css" rel="stylesheet" />
<script src="${sysResRoot}/jquery.js" type="text/javascript"></script>
<script type="text/javascript">
function addCart(orderId){
	$("#orderId").val(orderId);
    $("#jvForm").attr("action","${base}/cart/add_orderItem1.jspx");
	$("#jvForm").submit();
}
function addToCollect(productId,productFashId){
	$.post('${base}/collect/add_to_collect.jspx',{
		'productId':productId,
		'productFashId':productFashId
		}, function(data){
            if(data.status == 1){
            	 alert('收藏成功!');
            }else if(data.status== 2){
                    alert('收藏过该商品');
                }
            else{
            	location.href='${base}/login.jspx';
                }
        
			},'json');
}

function addToCart(productId,count,fashId,isAdd) {
	$.post('${base}/cart/add_orderItem.jspx', {
		'productId' : productId,
		'productAmount' : count,
		'fashId': fashId,
		'isAdd' : isAdd
	}, function(data) {
		if(data.status==1) {
			location.href='${base}/cart/shopping_cart.jspx?backUrl=${location}';
		} else if(data.status==0) {
			location.href='${loginUrl}';
		} else {
			alert(data.error);
		}
	},'json');
}
</script>

</head>
<body>
[#include "../include/shop_top.html"/]
<div class="w1168">
	[#include "店铺中心_导航.html"/]
    <div class="user_right">
    	<div class="user_title2">订单详情</div>  
    	<div class="clear10"></div> 
        [#if param??]
        	[#if param==true]
		        <form class="ropt">
		        <input type="submit" value="返回列表" onclick="this.form.action='deliverList.jspx?orderId=${order.id}&pageNo={pageNo}';" class="menu_ok2"/>
		        </form>
        	[#elseif param==false]	
		        <form class="ropt">
		        <input type="submit" value="返回列表" onclick="this.form.action='list.jspx?orderId=${order.id}&pageNo={pageNo}';" class="menu_ok2" />
		        </form>
		        <div class="clear10"></div> 
        	[/#if]
        [/#if]
        [#if op??]
        	[#if op==1]
        		[#if order.returnOrder??]
					[#if order.paymentStatus==2] 
						[#if order.shippingStatus==1]	
							[@s.m "order.PromptShippingStatusNo"/]
						[/#if]
						[#if order.shippingStatus==2]
							[@s.m "order.PromptShippingStatusYes"/]
						[/#if]
					[/#if]
				[#else]
			        <form id="jvForm" method="post" style="padding-top:5px">
			        <input type="hidden" name="id" value="${order.id}"/>
			        <input type="hidden" name="op" value="1"/>
			        <input type="hidden" name="pageNo" value="${pageNo!}"/>
			        <input type="hidden" name="param" value="false"/>
			        <input type="submit" style=" width:80px;" value="确认" onclick="this.form.action='o_affirm.jspx'" 
	        		[#if order.paymentStatus!=2]
	        			disabled
	        		[#elseif order.status!=1]
	        			disabled
	        		[/#if]/>
				        <input type="button" style="width:80px;" value="[@s.m 'order.paymentStatus.${order.paymentStatus!}'/]"/>
				        <input type="submit" style=" width:80px;" value="发货" onclick="this.form.action='v_sendGoods.jspx'" 
	        		[#if order.shippingStatus!=1]
	        			disabled
	        		[#elseif order.status!=2]
	        			disabled
	        		[#elseif order.paymentStatus!=2]
	        			disabled
	        		[/#if]/>
	        		<input type="submit" style=" width:80px;" value="完成" onclick="this.form.action='o_accomplish.jspx'" 
	        		[#if order.shippingStatus!=2]
	        			disabled
	        		[#elseif order.paymentStatus!=2]
			        	disabled
			        [#elseif order.status!=2]
			        	disabled
			        [/#if]/>
	        		<input type="submit" style=" width:80px;" value="取消" onclick="this.form.action='o_abolish.jspx'" 
	        		[#if order.status==3]
	       	 			disabled
	        		[#elseif order.shippingStatus==2]
	        			disabled
	        		[#elseif order.paymentStatus==2]
	        			disabled
	        		[#elseif order.status==4]
	        			disabled
	        		[/#if]/>
	        		</form> 
	        	[/#if]
        	[#elseif op==2]
        	[/#if]
        [/#if]
        <div class="clear10"></div>
        <div class="order_infod">
            <div class="order_conhead">
                <ul>
                    <li>订单编号：<span style="color:#fe0000;">${order.code}</span></li>
                    <li>下单日期：<span style="color:#fe0000;">${order.createTime}</span></li>
                    <li>订单状态<span style="color:#fe0000;">
                    [#if order.status=3]
                    [@s.m "order.status.${order.status}"/]
                    [#elseif order.status=4]
                    [@s.m "order.status.${order.status}"/]
                    [#elseif order.paymentStatus=1]
                    [@s.m "order.paymentStatus.${order.paymentStatus}"/]
                    &nbsp;[#if order.shippingStatus=2]
                    [@s.m "order.shippingStatus.${order.shippingStatus}"/]
                    [/#if]
                    [#elseif order.paymentStatus=2]
                    [@s.m "order.paymentStatus.${order.paymentStatus}"/]
                    &nbsp;[@s.m "order.shippingStatus.${order.shippingStatus}"/]
                    [/#if]
                    </span>
                    </li>
                </ul>
            </div>
            <div class="clear"></div>
            
            <div class="order_continf">
                <dl>
                <dt style="color:#06F">收货人信息</dt>
                <dd>收货人：${order.receiveName!}</dd>
                <dd>收货地址：${order.receiveAddress!} </dd>
                <dd>手机号码：${order.receiveMobile!}</dd>
                <dd>邮政编码：${order.receiveZip!}</dd>
                </dl>
                
                <dl>
                <dt style="color:#06F">配送信息</dt>
                <dd>送货方式：${order.shipping.name}</dd>
                <dd>运费：&yen;${order.freight!}</dd>
                <dd>物流单号: ${order.invoiceNo!}</dd>
                </dl>
                
                <dl>
                <dt style="color:#06F">支付信息</dt>
                <dd>支付状态：[#if order.status=3][@s.m "order.status.${order.status}"/][#elseif order.status=4][@s.m "order.status.${order.status}"/]
                [#elseif order.paymentStatus=1][@s.m "order.paymentStatus.${order.paymentStatus}"/]&nbsp;[#if order.shippingStatus=2][@s.m "order.shippingStatus.${order.shippingStatus}"/][/#if]
                [#elseif order.paymentStatus=2][@s.m "order.paymentStatus.${order.paymentStatus}"/]&nbsp;[@s.m "order.shippingStatus.${order.shippingStatus}"/][/#if]</dd>
                <dd>支付方式： ${order.payment.name}</dd>
                </dl>
                
                <dl>
                <dt style="color:#06F">积分信息</dt>
                <dd>可获积分：￥${order.score!0}[#if order.status==20](可用积分)[#else](冻结中)[/#if]
                <a class="hblue" href="${base}/xsrm/20.htm" target="_blank" style="color:#F00">查看积分规则</a>
                </dd>
                </dl>
                
                <div class="clear10"></div>
                <div class="order_info_list">
                <h3 style="color:#06F">商品信息</h3>
                    
                        <table cellspacing="1" cellpadding="0" border="0" class="product_table">
                        <tr><th width="60" height="30">商品图片</th><th>商品名称</th><th width="100">价格</th><th width="100">单重</th><th width="100">数量</th><th width="130">金额小计</th></tr>
                        [#list order.items as item]
                        <tr>
                        <td width="60" height="60" align="center" class="pro"><a href="http://www.yihaodian.com/product/1845672_3" target="_blank" style="float:none;"><img src="${base!}${item.product.productExt.coverImg!}" style="margin-right:0;float:none;"/></a></td>
                        <td class="pro1" align="left">
                        <p><a href="http://www.yihaodian.com/product/1845672_3" target="_blank">${item.product.name!}</a></p>
                        </td>
                        <td align="center">[#if item.productFash??]${item.salePrice!}[#else]${item.salePrice!}[/#if]</td>
                        <td align="center">${item.product.weight}</td>
                        <td align="center">${item.count!}</td>
                        <td align="center" width="130">${item.salePrice*item.count!}</td>
                        </tr>
                        [/#list]
                        </table>
                  
                    <div class="order_crash">
                        <ul>
                            <li><span>商品总金额：</span>&yen;${order.productPrice!}</li>
                            <li><span>运费：</span>+&yen;${order.freight!}</li>
                            <li class="order_crash_total"><span>发货前需先支付：</span><em>&yen;${order.total!}</em></li>
                      </ul>
                  </div>
                </div>
            
            </div>
        </div>
    </div>
	<div class="clear20"></div>
</div>
[#include "../include/footer_information_bar.html"/]
</body>
</html>